#-------------------------------------------------------------------------------
# SLABTRAN - a deterministic transport code for response function generation
#
# serment/src/slabtran/CMakeLists.txt
#
# $Rev:: 103                                           $:Rev of last commit
# $Author:: j.alyn.roberts@gma                         $:Author of last commit
# $Date:: 2011-06-14 22:22:46 -0400 (Tue, 14 Jun 2011) $:Date of last commit  
#
#-------------------------------------------------------------------------------

SET( SLABTRAN_DIR ${SERMENT_DIR}/src/slabtran )

# Add source for a separate slabtran build.
SET( SLABTRAN_SOURCE 
    # angle
    angle/AngularMesh.cc
    angle/Gauss_Legendre_1D.cc
    angle/Level_Symmetric_3D.cc
    angle/MomentsIndex.cc
    angle/Moment_to_Discrete.cc
    angle/Octant.cc
    angle/Quadrature.cc
    angle/QuadratureFactory.cc
    angle/Quadruple_Range_2D.cc
    angle/Spherical_Harmonics.cc
    angle/Uniform_Equal_3D.cc
    # driver
    driver/slabtran.cc
    driver/SlabtranInput.cc
    driver/SlabtranProblem.cc
    # material
    material/BuiltInCrossSections.cc
    material/Cross_Section.cc
    material/Materials.cc
    # source
    source/BaseSource.cc
    # tran
    tran/CartMesh.cc
    tran/DD_1D_Equations.cc
    tran/DD_2D_Equations.cc
    tran/DD_3D_Equations.cc
    tran/FissionSource.cc
    tran/Moments_Field.cc
    tran/Psi_Cell_Field.cc
    tran/State.cc
    tran/SweepSource.cc
)

# Add include directories
INCLUDE_DIRECTORIES( ${SLABTRAN_DIR}/angle )
INCLUDE_DIRECTORIES( ${SLABTRAN_DIR}/driver )
INCLUDE_DIRECTORIES( ${SLABTRAN_DIR}/material )
INCLUDE_DIRECTORIES( ${SLABTRAN_DIR}/source )
INCLUDE_DIRECTORIES( ${SLABTRAN_DIR}/tran )

# Build the SLABTRAN executable
if( SERMENT_BUILD_SLABTRAN )
    ADD_EXECUTABLE( slabtranx 
                    ${SLABTRAN_SOURCE} 
    )
    TARGET_LINK_LIBRARIES( slabtranx 
                           utils
                           ${LIBXML2_LIBRARIES} 
    )
endif()

# Add testing, if required.
if( SERMENT_ENABLE_TEST )
    ADD_SUBDIRECTORY( ${SLABTRAN_DIR}/test )
endif()



